package com.eliza.kotlin.base.oop

import org.junit.jupiter.api.Test

/*-*- coding:utf-8 -*-
 * @Author  : debi
 * @Time    : 6/4/22
 * @Software: IntelliJ IDEA
 */
internal class IITest {
    @Test
    fun run1() {
        AA().show(object : InterFace {
            override fun show(info: String) {
                println("aaa")
            }

        })
    }

    @Test
    fun run2() {

        AA().show2 { info: String ->
            println("------")
            println(info)
        }
    }

    @Test
    fun run4() {

        AA().show4(object : InterFace {
            override fun show(info: String) {
                println(info)

                println("------")
                println("------")
            }
        }) { i: InterFace ->
            i.show("asz")
        }
    }

    @Test
    fun run3() {

        AA().show() { info ->
            println("------$info")
        }
    }

}